<!--
 * @Description: 咨询详情
 * @Author: yangxq
 * @Date: 2019-09-10 19:50:59
 * @LastEditTime: 2019-09-12 11:10:07
 * @LastEditors: Please set LastEditors
 -->
<template>
  <div class="messageDetail-wrap">
    <div class="topNavs">
      <van-nav-bar title="详情"
                   left-arrow
                   @click-left="$router.go(-1)" />
      <div class="info">
        <div class="info-html"
             v-html="info.informationContent">

        </div>
      </div>

    </div>
  </div>
</template>

<script>
export default {
  data () {
    return {
      infoId: "",
      info: ""
    }
  },
  mounted () {
    this.infoId = this.$route.params.id;
    this.getSecurityInfoById();
  },
  methods: {
    getSecurityInfoById () {
      let params = {
        infoId: this.infoId
      };
      this.$http.post("getSecurityInfoById", params).then((res) => {
        if (res.data.code == "success") {
          this.info = res.data.data;
        } else {
          console.log(res.data);
        }
      }).catch(function (error) {
        console.log(error);
      })
    },
  }
}
</script>

<style lang="scss" >
@import "@/assets/css/common.scss";
.messageDetail-wrap {
  font-size: 0.4rem;
  line-height: 1.5;
  .info-html {
    img {
      max-width: 90% !important;
      margin: 0 auto;
      border-radius: 10px;
    }
  }
  .info {
    width: 88%;
    margin: 0 auto;
  }
}
</style>